Creates and executes a LearningStoreJob that removes the package referenced by packageId from PackageStore. This action is permanent and deleted information cannot be recovered.
Parent Type: PackageStore
Namespace: Microsoft.LearningComponents.Storage
Assembly: Microsoft.LearningComponents.Storage.dll
| C# |
|
protected string RemovePackageReference ( ) |
packageId
The package reference to remove.
The Location value of the package. The derived class should take appropriate action to clean up any cached files in this location.
| Exception type | Condition |
| LearningStoreConstraintViolationException | Thrown if the package cannot be deleted from LearningStore because there are other items in the store that depend upon it. For instance, a package for which there are attempts in LearningStore, cannot be deleted. |
| ArgumentNullException | Thrown if packageId is not provided. |
| LearningStoreItemNotFoundException | Thrown if packageId does not represent a package in LearningStore. |
In order to remove the package reference, there must no other dependencies on the package. For instance, if the package has been executed, the resulting attempt information must be removed from LearningStore before the package reference may be removed.